using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

using BLL;
using BLL.Impl;

namespace WebUI.Admin.Role
{
    public partial class Role_Modify : System.Web.UI.Page
    {
        private IAdminManager adminManager;
        protected void Page_Load(object sender, EventArgs e)
        {
            adminManager = BLLFactory.CreateAdminManager();
        }

        protected void btnModify_Click(object sender, EventArgs e)
        {
            Model.Role role = new Model.Role();
            role.RoleName = this.txtRoleName.Text;
            adminManager.SaveRole(role);
            Response.Redirect("Role_List.aspx");
        }

        protected void btnReset_Click(object sender, EventArgs e)
        {
            this.txtRoleName.Text = "";
        }
    }
}
